package org.fxd;

import com.deepoove.poi.XWPFTemplate;

import java.io.FileOutputStream;
import java.util.HashMap;

public class Main {

    public static void main(String[] args) throws Exception {

        XWPFTemplate template = XWPFTemplate.compile("E:\\log\\template.docx").render(
                new HashMap<String, Object>() {{
                    put("title", "Hi, poi-tl Word模板引擎");
                }});
        template.writeAndClose(new FileOutputStream("E:\\log\\output.docx"));
    }

}
